import Vue from 'vue'
import App from './App.vue'
import { router } from './router'
import Vant from 'vant'
import 'vant/lib/index.css'
import 'amfe-flexible'
// import 'normalize.css'
import  FastClick  from  'vue-fastclick'
import '../public/fonticon/iconfont.css'
import './removedefault.css'
// import './until/jweixin-1.0.0' // 导入api接口


// import VConsole from 'vconsole'
// let vConsole = new VConsole() // 初始化
// console.log(vConsole)

import VuePreview from 'vue-preview'

// defalut install
Vue.use(VuePreview)

// with parameters install
Vue.use(VuePreview, {
  mainClass: 'pswp--minimal--dark',
  barsSize: {top: 0, bottom: 0},
  captionEl: false,
  fullscreenEl: false,
  shareEl: false,
  bgOpacity: 0.85,
  tapToClose: true,
  tapToToggleControls: false
})

import api from './until/api' // 导入api接口
Vue.prototype.$api = api; // 将api挂载到vue的原型上
import env from './until/base'
Vue.prototype.env = env.env;

Vue.use(Vant);

Vue.config.productionTip = false
if ('addEventListener' in document) {
  document.addEventListener('DOMContentLoaded', function () {
    FastClick.attach(document.body)
  }, false);
}
new Vue({
  router,
  render: h => h(App),
}).$mount('#app')
